package Eyjafjalla.action;

import Eyjafjalla.card.attack.VolcanoStone_Eyjafjalla;
import com.megacrit.cardcrawl.actions.AbstractGameAction;
import com.megacrit.cardcrawl.cards.AbstractCard;

public class VolcanoEchoAction extends AbstractGameAction {
    public VolcanoEchoAction(boolean upgraded,int block,int amt){
        this.amount = amt;
        if(this.amount<1){
            this.amount = 1;
        }
        this.block = block;
        if(this.block<0){
            this.block = 0;
        }
        this.upgraded = upgraded;
    }

    int block;
    boolean upgraded;

    @Override
    public void update() {
        AbstractCard stone = new VolcanoStone_Eyjafjalla();
        if(upgraded){
            stone.upgrade();
        }
        stone.baseDamage+=this.block;
        stone.damage = stone.baseDamage;
        addToTop(new MakeTempCardInCloudAction(stone,this.amount));
        this.isDone = true;
    }
}
